1. Technical Field
The present invention is directed to data processing systems. More specifically, the present invention is directed to a method, system, and computer program product for avoiding data loss during a network port's recovery process.
2. Description of Related Art
In an ideal data processing system networking environment, the network ports, also called adapters, are operational at all times once they have been initialized and have addresses resolved. However, the reality is that often times a small number of ports experience some kind of port failure while in operation due to hardware or software defects. These failures may cause the port to hang, i.e. the port will not respond, in some cases. Once a port hangs, the port needs to complete a recovery process before it can become active and responsive again.
The known method to recover a port is to issue a soft reset to the port which will then cause the port to reinitialize itself. The process of reinitializing the port takes some period of time. During this time period of re-initialization, the port software and hardware are not ready or available to receive any packets from the network. Any packets sent to the port during this reinitialization process will be lost. To compound this problem, the system that transmitted the lost data to the port will be unaware that the intended recipient port is in a recovery mode and is not receiving the data.
A data processing system may be linked to another data processing system via the network in order to transmit data between these linked systems utilizing a network port in each system. When a first data processing system is linked to a second data processing system, the first data processing system will assume that because the systems are linked that the second system is ready to receive data via the second system's network port.
An Ethernet port includes a media access controller (MAC) and a network physical (PHY) layer. The logic to establish an Ethernet link connection between the ports is in the physical layer of the Ethernet port and is independent from the MAC and the device driver software that executes a recovery of the port. As soon as a port receives a power on signal or a soft reset signal, the PHY will start link negotiations with a second data processing system that is to become its linked partner. The link can be accomplished very quickly and long before the port software (device driver) and hardware (MAC) are ready to receive any data via the port. During the recovery period, there can be a significant data loss if the data keeps coming from the linked data processing system into the failed port.
Therefore, a need exists for a method, system, and computer program product for avoiding data loss during a network port recovery process.